home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 13131 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.9 KB

  1. Path: news.iadfw.net!usenet
  2. From: Larry Weiss <lfw@iadfw.net>
  3. Newsgroups: comp.lang.eiffel,comp.lang.c,comp.lang.c++,comp.object,comp.software-eng
  4. Subject: Re: Beware of "C" Hackers -- A rebuttal to Bertrand Meyer
  5. Date: Sat, 23 Mar 1996 14:13:58 -0600
  6. Organization: customer of Internet America
  7. Message-ID: <31545B86.4CC0@iadfw.net>
  8. References: <1995Jul3.034108.4193@rcmcon.com> <4i862r$1evq@saba.info.ucla.edu> <64ss5$3F3RB@herold.franken.de> <314DADD4.3DE@oc.com> <4j1gmu$crl@solutions.solon.com>
  9. NNTP-Posting-Host: dal20-22.ppp.iadfw.net
  10. Mime-Version: 1.0
  11. Content-Type: text/plain; charset=us-ascii
  12. Content-Transfer-Encoding: 7bit
  13. X-Mailer: Mozilla 2.01 (Win16; I)
  14.  
  15. Peter Seebach wrote:
  16.  > 
  17.  > >In the old days, when the Standard library was just another set of linkable
  18.  > >entry points, it was straightforward to replace the vendor's logic with
  19.  > >your own (maybe just the same with tracepoint logic, but maybe a very
  20.  > >experimental replacement, and maybe a "better" one).   No more!
  21.  > 
  22.  > It's still straightforward; you write your own logic, and then use a function
  23.  > which uses your logic.  If your logic doesn't work, you just make the function
  24.  > a stub around the library routine.
  25.  > 
  26.  > This is SOP if you don't quite like the semantics of a library call, and also
  27.  > makes it easier to work around vendor bugs.
  28.  > 
  29.  > I don't do it for most calls, but I bring it in occasionally.
  30.  > 
  31.  > For instance, most of the functions in the stdlib that take a single
  32.  > char * argument, I have stubs for which take (char *, ...) and do
  33.  > "the right thing" with vsprintf.  Easy!
  34.  > 
  35.  
  36. I don't understand.  Suppose that I want to substitute my strlen() logic
  37. for the vendors implementation of strlen() in such a way that not only
  38. my source's calls on strlen() are affected, but also any 3rd party's
  39. library's uses of strlen() get the "benefit".   How does your technique
  40. apply to that scenario?
  41.